package com.zhz.common.tool.mybatisplus.base.core.contract;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

import javax.validation.constraints.NotNull;
import javax.validation.groups.Default;
import java.io.Serializable;

/**
 * @author zhouhengzhe
 * @date 2023/3/23
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@SuperBuilder
public class BaseRequest implements Serializable {

    @NotNull(message = "id不能为空", groups = {Update.class, Delete.class})
    private String id;
    /**
     * 保存和缺省验证组
     */
    public interface Save extends Default {

    }

    /**
     * 更新和缺省验证组
     */
    public interface Update extends Default {

    }

    /**
     * 更新和缺省验证组
     */
    public interface Delete extends Default {

    }
}
